<?php
namespace Home\Controller;
use Think\Controller;
class TemplateController extends Controller {
    public function index(){
        $this->assign('name', 'everyone');

        $data['name'] = 'yangweijie';
        $data['email'] = '917647288@qq.com';
        $this->assign('data',$data);

        $_GET['pageNumber'] = 1;
        $_SESSION['user_id'] = 1;
        $_COOKIE['name'] = '杨维杰';

        $this->assign('cal',array('num1'=>1,'num2'=>2));

        $this->assign('status', 1);
        $this->display();
    }
}